package com.bw.liveplay.common.bind

import androidx.databinding.BindingAdapter
import androidx.recyclerview.widget.LinearLayoutManager
import androidx.recyclerview.widget.RecyclerView
import com.chad.library.adapter.base.BaseQuickAdapter

/**
 * @author KK
 * @description:
 * @date :2021/11/10 13:58
 *
 */
class HomeFeedBind {
    companion object{
        @JvmStatic
       @BindingAdapter(value = ["adapter"])
        fun bindFeedRv(recyclerView: RecyclerView,adapter: BaseQuickAdapter<*,*>){
            val manager = LinearLayoutManager(recyclerView.context)
            manager.orientation = LinearLayoutManager.VERTICAL
            recyclerView.layoutManager = manager
            recyclerView.adapter = adapter
        }


    }
}